/********************************************************************************
 * Project Name		[JavaSE_Fundamentals]
 * File Name     	[TestDate.java]
 * Creation Date 	[2015-01-01]
 * 
 * Copyright© ge.y.yang@gmail.com All Rights Reserved
 * 
 * Work hard, play harder, think big and keep fit
 ********************************************************************************/
package api.util;

/**
 * java.uti.Date测试
 * 
 * @author 不落的太阳(Sean Yang aka ShortPeace)
 * @version 1.0
 * @since jdk 1.8
 * 
 */
public class TestDate {

	public static void main(String[] args) {
		java.util.Date utilDate = new java.util.Date();
		System.out.println("java.util.Date = " + utilDate);

		// java.util.Date和java.sql.Date的相互转换
		java.sql.Date sqlDate = new java.sql.Date(utilDate.getTime());
		System.out.println("java.sql.Date = " + sqlDate);

		utilDate = new java.util.Date(sqlDate.getTime());
		System.out.println("java.util.Date = " + utilDate);
	}
}
